import http from './http.js'
import qs from 'qs'
//登录模块控制js
/**
 * 登录api
 * @param {username:xxx,password:xxx} data
 */
export function login(data) {
  return http({
    method: 'post',
    url: `/login`,
    data: qs.stringify({ username: data.username, password: data.password }),
  })
}
